package com.seqb.manage.user.domain;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import com.seqb.common.dto.CommDTO;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * @author lilinshen
 * @title 用户科目表
 * @description 请填写相关描述
 * @date 2019-12-04
 */
@Data
@TableName("t_user_subject")
public class UserSubjectDO extends CommDTO implements Serializable {
    private static final long serialVersionUID = 1L;

    //唯一编号
    private Long id;
    //用户ID
    private Long userId;
    //科目ID
    private Long subjectId;
    //科目名称
    private String subjectName;
    //正确率
    private Double accuracyRate;
    //做题总数
    private Long totalQuestion;
    //收藏总数
    private Long totalCollect;
    //错题总数
    private Long totalWrong;
    //是否开启答对2次自动移除错题(0-否，1-是)
    private String autoRemove;
    //是否为当前选择(0-否，1-是)
    private String currentChoice;
    //创建者编号
    @TableField(fill = FieldFill.INSERT)
    private Long createNumber;
    //创建时间
    @TableField(fill = FieldFill.INSERT)
    private Date createDate;
    //修改时间
    @TableField(fill = FieldFill.INSERT_UPDATE, update = "now()")
    private Date updateDate;
    //是否删除(0-否，1-是)
    @TableLogic
    @TableField(fill = FieldFill.INSERT)
    private String isDelete;
    //版本号
    @TableField(fill = FieldFill.INSERT_UPDATE, update = "%s+1")
    private Long version;
}
